// eslint-disable-next-line
import {
  UserLayout,
  BasicLayout,
  BasicLayout_comprehensive,
  BasicLayout_factory,
  BasicLayout_revenue,
  BasicLayout_pipe,
  BasicLayout_example,
  BasicLayout_system,
  BasicLayout_customer,
  BasicLayout_workorder,
  RouteView,
  BlankLayout,
  PageView
} from '@/layouts'
import { bxAnaalyse } from '@/core/icons'

export const asyncRouterMap = [


  {
    path: '/revenue',
    name: 'revenue',
    component: BasicLayout_revenue,
    redirect: '/revenue/home',
    children: [
      {
        path: '/revenue/home',
        name: 'revenue_home',
        component: () => import('@/views/revenue/home'),
        meta: { title: '首页', keepAlive: false, icon: 'form' }
      },
    ]

  },

  {
    path: '*', redirect: '/404', hidden: true
  }
]

//export const asyncRouterMap = [ ]

/**
 * 基础路由
 * @type { *[] }
 */
export const constantRouterMap = [
  {
    path: '/',
    name: 'index',
    component: BasicLayout,
    redirect: '/revenue',
    children: [ ]
  },

  {
    path: '/user',
    component: UserLayout,
    redirect: '/user/login',
    hidden: true,
    children:
      [
        {
          path: 'login',
          name: 'login',
          component: () => import(/* webpackChunkName: "user" */ '@/views/user/Login')
        },
        {
          path: 'register',
          name: 'register',
          component: () => import(/* webpackChunkName: "user" */ '@/views/user/Register')
        },
        {
          path: 'register-result',
          name: 'registerResult',
          component: () => import(/* webpackChunkName: "user" */ '@/views/user/RegisterResult')
        },
        {
          path: 'recover',
          name: 'recover',
          component: undefined
        }
      ]
  },

  {
    path: '/test',
    component: BlankLayout,
    redirect: '/test/home',
    children: [
      {
        path: 'home',
        name: 'TestHome',
        component: () => import('@/views/revenue/home')
      }
    ]
  },

  {
    path: '/404',
    component: () => import(/* webpackChunkName: "fail" */ '@/views/exception/404')
  }

]
